package com.hospital.pet.love.lovepethospital.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * @TableName case
 */
@TableName(value = "t_case")
@Data
public class Case implements Serializable {
    /**
     * 唯一标识
     */
    @TableId(value = "case_id", type = IdType.AUTO)
    private Integer caseId;

    /**
     * 挂号id
     */
    @TableField(value = "register_id")
    private Integer registerId;

    /**
     * 病情描述
     */
    @TableField(value = "disease_description")
    private String diseaseDescription;

    /**
     * 诊断结果
     */
    @TableField(value = "diagnosis")
    private String diagnosis;

    /**
     * 治疗方案
     */
    @TableField(value = "treatment")
    private String treatment;

    /**
     * 诊断时间
     */
    @TableField(value = "case_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime caseTime;

    /**
     * 支付金额
     */
    @TableField(value = "pay_money")
    private BigDecimal payMoney;

    /**
     * 支付状态
     */
    @TableField(value = "pay_state")
    @Schema(description = "0 未支付 1 已支付")
    private Integer payState;

    /**
     * 就诊状态
     */
    @TableField(value = "visit_state")
    @Schema(description = "0 就诊 1 支付完成 2 取消")
    private Integer visitState;

    @Serial
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}